<!DOCTYPE html>
<html>

<head>
    <meta http-equiv="X-UA-Compatible" content="IE=10">
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    <title>lims_heat_treatment</title>
</head>

<body>
    <div id="app"></div>
    <!-- built files will be auto injected -->
</body>

<script language='javascript'>
    document.onkeydown = function(evt) {
        //document.all可以判断浏览器是否是IE，是页面内所有元素的一个集合
        var isie = (document.all) ? true : false;
        var key;
        var srcobj;
        // if the agent is an IE browser, it's easy to do this.
        if (isie) {
            key = event.keyCode;
            srcobj = event.srcElement; //event.srcElement，触发这个事件的源对象
        } else {
            key = evt.which;
            srcobj = evt.target; //target是Firefox下的属性
        }
        if (key == 13 && srcobj.type != 'button' && srcobj.type != 'submit' && srcobj.type != 'reset' && srcobj.type != 'textarea' && srcobj.type != '') {
            if (isie)
                event.keyCode = 9; //设置按键为tab键
            else {
                var el = getNextElement(evt.target);
                if (el.type != 'hidden')
                ; //nothing to do here.
                else
                    while (el.type == 'hidden')
                        el = getNextElement(el);
                if (!el)
                    return false;
                else
                    el.focus();
            }
        }
    }


    function getNextElement(field) {
        var form = field.form;
        for (var e = 0; e < form.elements.length; e++) {
            if (field == form.elements[e])
                break;
        }
        return form.elements[++e % form.elements.length];
    }

</script>

<style>
    .el-input-number .el-input__inner {
        text-align: left !important;
    }

    input::-webkit-outer-spin-button,
    input::-webkit-inner-spin-button {
        -webkit-appearance: none !important;
        margin: 0;
    }

    input[type="number"] {
        -moz-appearance: textfield;
    }

</style>

</html>
